package org.dtrd.modules.record.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.dtrd.modules.record.entity.po.DtrdEntRdSigninInsulin;

import java.util.List;

public interface DtrdEntRdInsulinMapper extends BaseMapper<DtrdEntRdSigninInsulin> {

    Integer countGroupInsulinRecord(Integer patientId, String startDate, String endDate);

    List<DtrdEntRdSigninInsulin> getAllGroupedInsulinRecord(@Param("patientId") Integer patientId,
                                                            @Param("startDate") String startDate,
                                                            @Param("endDate") String endDate);

    List<DtrdEntRdSigninInsulin> selectInsulinRecordsForChart(@Param("patientId") Integer patientId,
                                                              @Param("startDate") String startDate,
                                                              @Param("endDate") String endDate);
}